import cv2
import numpy as np

img = cv2.imread('1.jpg')
## 越靠近 占比计算越高
new_img = cv2.GaussianBlur(img,(5,5),1)
## 排序以后取中间值  只要中间值不是自己 那么就会排除掉所有噪音点
median_img = cv2.medianBlur(img,5)
# cv2.imshow('img',img)
# cv2.imshow('new_img',new_img)
# cv2.imshow('median_img',median_img)
all_img = np.hstack([img,new_img,median_img])
cv2.imshow('all_img',all_img)
cv2.waitKey(0)
cv2.destroyAllWindows()

